<?php

/**
 * Usuario form.
 *
 * @package    aeropostal
 * @subpackage form
 * @author     Your name here
 */
class UsuarioForm extends BaseUsuarioForm
{
  public function configure()
  {
	$this->setWidgets(array(
      'codigo'    => new sfWidgetFormPropelChoice(array('model'=> 'Empleado','add_empty' => '--Seleccione un c&oacute;digo de Empleado--','key_method' => 'getCodigo')),
	  'login'    => new sfWidgetFormInput(),
	  'password'   => new sfWidgetFormInputPassword,
    ));
	
	//$this->form->setDefault('nombre', 'yy'); 
	
	$this->widgetSchema->setLabels(array(
	  'codigo'    => 'C&oacute;digo',
	  'password'      => 'Contrase&ntilde;a',
	));
	
	$this->widgetSchema->setNameFormat('Usuario[%s]');
	$this->errorSchema = new sfValidatorErrorSchema($this->validatorSchema);
  }
}
